In actual networking application, a network constructed by using a large number of single-segment pseudo wires (Single-Segment Pseudo-Wire, SS-PW) brings great pressure on a service convergence device. A multi-segment pseudo-wire (Multi-Segment Pseudo-Wire, MS-PW) technology is proposed in the field of pseudo-wire emulation edge to edge (Pseudo-Wire Emulation Edge to Edge, PWE3) technologies, where a switching provider edge (Switching PE, S-PE, hereinafter referred to as SPE) is mainly used to relieve pressure of a convergence device and solve cross-domain deployment and security problems of a network.
Referring to FIG. 1a, in a networking system constructed by using an MS-PW, when a local customer edge (CE1) communicates with a peer CE2, the communication needs to implement through a terminating provider edge (Terminating Provider Edge, TPE1) of a service provider, where the terminating provider edge is directly connected to the local CE1, and pseudo-wire connections to a TPE3 and a TPE4 respectively by passing through an SPE1 and an SPE2 are established. A pseudo wire between PEs (including a TEE and a SPE) is established through the following steps:
1: Establish session connections between the TPE1 and the SPE1, the SPE2 as well as the TPE3; and establish session connections between the TPE1 and the SPE1, the SPE2 as well as the TPE4.
2: Establish a PW route through a routing protocol.
3: The TPE1 sends a label mapping message (label mapping) to establish a multi-segment pseudo wire from the TPE1 to the TPE3; and the TPE1 sends a label mapping message to establish another multi-segment pseudo wire from the TPE1 to the TPE4, where one of the multi-segment pseudo Wires may be set as an active pseudo wire during an establishment process.
4: After receiving the label mapping message, the TPE3 or the TPE4 finishes establishing a reverse pseudo wire to the TPE1.
After the preceding pseudo wires are established, when communication is established between two customer edges, and when a TPE finds that the active pseudo wire fails, an active/standby pseudo wire switchover is performed. In this way, the active/standby pseudo wire switchover can only be completed from a local TPE to a peer TPE, so that a pseudo wire protection switchover between customer edges lasts for a long time.